<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">  
<html>
  <head>
  <base target="_self"/>
  
  <title>表单基本信息修改页面</title>
  	<meta http-equiv="X-UA-Compatible" content="IE=7" />
  	<%@ include file="../jslib/jquerylib.jsp" %>
  	<link rel="stylesheet" type="text/css" href="<%=path %>/web/style/layout.css" />
    <script type="text/javascript" src="<%=path %>/jqGrid/js/jquery-1.7.2.min.js"></script>
    <script type="text/javascript" src="<%=path %>/jslib/jquery.validate.min.js"></script>
    <script type='text/javascript' src="<%=request.getContextPath() %>/jslib/My97DatePicker/WdatePicker.js" defer="defer"></script>
    <script type='text/javascript' src="<%=request.getContextPath() %>/jslib/jquery.form.js"></script>
    <script type="text/javascript" src="<%=request.getContextPath() %>/jslib/additional-methods.js"></script>
    <link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/jslib/jquery-easyui-1.4.1/themes/default/easyui.css">
	<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/jslib/jquery-easyui-1.4.1/themes/icon.css">
	<link rel="stylesheet" type="text/css" href="<%=request.getContextPath() %>/jslib/jquery-easyui-1.4.1/demo.css">
	<script type="text/javascript" src="<%=request.getContextPath() %>/jslib/jquery-easyui-1.4.1/jquery.easyui.min.js"></script>
    <c:if test="${requestScope.message!=null}">
		<script type="text/javascript">
 	 		     alert('<c:out value="${requestScope.message}"></c:out>');
 	 		     window.close();
 		</script>
	</c:if>
	<style type="text/css">
   		html{
		    overflow-x: hidden;
		}  		
   </style>
    <script type="text/javascript">
    $().ready(function() {
				
    	// 准备好Options对象
    	var options = {
    	    url:'<%=request.getContextPath() %>/filemodeAction!updateYsjlForm.action',
    	    dataType:'json',
    	    success: function(data) {
    	      if(data.result=='success'){
				alert("操作成功");
				window.close();
    	      }else{
    	      	alert("系统繁忙，请您稍后再试！");
    	      	window.close();
    	      }
    	}};
    	
		$('#saveBtn').click(function(){
			$('#pageFrom').ajaxSubmit(options);
			return false;
		});
		
		$('#closeBtn').click(function(){
			window.close();
		});

	});


	function selectbaseinfo(){
		var k = window.showModalDialog("<%=request.getContextPath() %>/resource/choose/selectForm.jsp?type=flow", window, "dialogWidth:820px;status:no;dialogHeight:500px");
        if (k != null) {
            var infos = k.split(',');
            document.getElementById("BASEINFOID").value = infos[0];
            document.getElementById("BASEINFONAME").value = infos[1];
        }
	}
	
	function selectdatainfo(){
		var k = window.showModalDialog("<%=request.getContextPath() %>/resource/choose/selectForm.jsp?type=flow", window, "dialogWidth:820px;status:no;dialogHeight:500px");
        if (k != null) {
            var infos = k.split(',');
            document.getElementById("DATAINFOID").value = infos[0];
            document.getElementById("DATAINFONAME").value = infos[1];
        }
	}
</script>

 <style type="text/css">
	body{
		background:#ffffff; background-image:url(images/);
	}
	.tab_input{border: 1px solid #999;padding: 5px;width: 250px;-moz-border-radius: 3px;border-radius: 3px;margin-bottom: 5px;color: #666;background: url(../images/input_bg.gif) repeat-x top;}
</style>
</head>
<body>
  	<form id="pageFrom" name="pageFrom"  method="post">
  		<table width="100%" border="0" align="center">
  			<tr><td align="right">选择表单信息：</td>
  			    <td align="left">
  			       <input type="hidden" id="BASEINFOID" name="BASEINFOID"  value="${BASEINFOID }">
  			       <input type="text" readonly id="BASEINFONAME" name="BASEINFONAME" value="${BASEINFONAME }" style="border: 1px solid #999;padding: 5px;width: 250px;" />
  			       <img src="web/images/form_icon_1.gif" style="cursor:hand; vertical-align: middle;" onclick="selectbaseinfo()" />
  			       </td>
  			</tr>
  			<tr><td align="right">选择数据信息：</td>
  			    <td align="left">
  			       <input type="hidden" id="DATAINFOID" name="DATAINFOID"  value="${DATAINFOID }">
  			       <input type="text" readonly id="DATAINFONAME" name="DATAINFONAME" value="${DATAINFONAME }"  style="border: 1px solid #999;padding: 5px;width: 250px;" />
  			       <img src="web/images/form_icon_1.gif" style="cursor:hand; vertical-align: middle;" onclick="selectdatainfo()" />
  			       </td>
  			</tr>
		</table>
		<table width="100%" border="0" align="center" class="formTableNew">
			<td align="center">
		    	<input id="saveBtn" type="button" value="保 存" class="form_bt_orange" /
		      	<input type="button" id="closeBtn" value="取 消" class="form_bt_grey" />
		    </td>
		</table>
		<input type="hidden" id="YSJLID" name="YSJLID"  value="${YSJLID }">
	</form>
  </body>
</html>
